package com.ge.pp;

public class FilterAttribute {
	public String name;
	public float min;
	public float max;
	float val;
	public FilterAttribute(String _name) {
		name= _name; min = 0; max = 0; val = 0;
	}
	public FilterAttribute(String _name, float _min, float _max, float _val) {
		name = _name; min = _min; max= _max; 
		if (_val <min)
			val = min;
		else if (_val > max) 
			val = max;
		else			
			val = _val;
	}
	
	public void set(float _val) {
		if (_val <min)
			val = min;
		else if (_val > max) 
			val = max;
		else			
			val = _val;		
	}
	
	public float get() {
		return val;
	}
}